package cn.adkii.mybatis.transaction;

import java.sql.Connection;
import java.sql.SQLException;

/**
 * @author malingdi
 * @description 定义事务的标准接口，链接、提交、回滚、关闭，具体可以由不同的事务方式进行实现
 * @date 2023/12/5 11:07
 */
public interface Transaction {

    Connection getConnection() throws SQLException;

    void commit() throws SQLException;

    void rollback() throws SQLException;

    void close() throws SQLException;
}
